package top.codedance.iotp.client.plugins.sync.client;

import top.codedance.iotp.client.ClientApplication;
import top.codedance.iotp.common.executer.SyncAbstractExecuter;
import top.codedance.iotp.common.entity.PluginResultEntity;

public class ViewVersionExecuterImpl extends SyncAbstractExecuter {

    @Override
    public PluginResultEntity exec(byte[] data, String taskId) {
        PluginResultEntity result = new PluginResultEntity();
        try {
            result.setOk(true);
            result.setContext(ClientApplication.VERSION);
        }catch (Exception ex){
            result.setOk(false);
            result.setMsg(ex.getMessage());
        }
        return result;
    }
}